import http from '../request'
/* 注册 */
export const register = (data) =>
  http({
    url: '/user/register',
    data,
    method: 'POST',
    headers: {
      'Content-type': 'multipart/form-data'
    }
  })

/**
 * 发送验证码
 */
export const sendCode = (data) =>
  http({
    url: '/user/sendCode',
    data,
    method: 'POST'
  })

/* 登录 */
export const login = (data) =>
  http({
    url: '/user/login',
    data,
    method: 'POST'
  })
